<template>
  <a-row type="flex" :gutter="16">
    <a-col :md="5" :sm="24">
<!--      <staff-tree v-model="currentOrgCode" @selectedNode="selectedNode"/>-->
      <education-and-service-staff-tree v-model="currentOrgCode" @selectedNode="selectedNode" ></education-and-service-staff-tree>
    </a-col>
    <a-col :md="24-5" :sm="24">
      <education-and-service-list v-if="nodeObj.isLeaf" v-model="nodeObj"></education-and-service-list>
      <education-and-service-import v-if="!nodeObj.isLeaf" v-model="nodeObj"></education-and-service-import>
    </a-col>
  </a-row>
</template>

<script>
import EducationAndServiceList from '@views/gfxy/educationandservice/EducationAndServiceList'
import EducationAndServiceImport from '@views/gfxy/educationandservice/EducationAndServiceImport'
import EducationAndServiceStaffTree from '@views/gfxy/educationandservice/EducationAndServiceStaffTree'

export default {
  name: "EducationAndService",
  components: { EducationAndServiceImport, EducationAndServiceList,EducationAndServiceStaffTree },
  data(){
    return {
      currentOrgCode: '',
      nodeObj:{}
    }
  },
  methods: {
    selectedNode(nodeObj){
      console.log(nodeObj)
      this.nodeObj = nodeObj
      this.$nextTick(()=>{

      })
    }

  },
}
</script>

<style scoped>

</style>